package com.yc.demo.web;

import com.yc.demo.HelloProperties;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("demo")
public class HelloAction {

    @Autowired
    HelloProperties helloProperties;

    @RequestMapping("hello")
    public String hello(){
        return "hello " + helloProperties.getName();
    }
}
